<?php 
if($_POST['user'] == "kvbhat"){
	$password = $_POST['pwd'];
	// get the hash of appa's pwd
	//$hash = file_get_contents('lib/pwd.txt');
	$hashed_password = file_get_contents('lib/pwd.txt');
	
	if (crypt($password, $hashed_password) == $hashed_password) {
		session_start();
		$_SESSION['logged_in'] = true;
		header('Location: ' . "manage");
	} else {
		echo "Wrong username or password. Try again";
	}
} else {
		echo "Wrong username or password. Try again :)";
}
?>